<file>dbusService.js</file>
<file>extensions/sharedInternals.js</file>
+ <file>extensions/prefs.js</file>
<file>misc/config.js</file>
<file>misc/extensionUtils.js</file>
--- /dev/null
+import {getCurrentExtension} from './sharedInternals.js';
+
+export {
+ getSettings,
+ initTranslations,
+ gettext,
+ ngettext,
+ pgettext
+} from './sharedInternals.js';
+
+/**
+ * Open the preference dialog of the current extension
+ */
+export function openPrefs() {
+ const extension = getCurrentExtension();
+
+ if (!extension)
+ throw new Error('openPrefs() can only be called from extensions');
+
+ try {
+ const extensionManager = imports.ui.main.extensionManager;
+ extensionManager.openExtensionPrefs(extension.uuid, '', {});
+ } catch (e) {
+ if (e.name === 'ImportError')
+ throw new Error('openPrefs() cannot be called from preferences');
+ logError(e, 'Failed to open extension preferences');
+ }
+}
--- /dev/null
+export {
+ getSettings,
+ initTranslations,
+ gettext,
+ ngettext,
+ pgettext
+} from './sharedInternals.js';
return new Gio.Settings({settings_schema: schemaObj});
}
-
-/**
- * Open the preference dialog of the current extension
- */
-export function openPrefs() {
- const extension = getCurrentExtension();
-
- if (!extension)
- throw new Error('openPrefs() can only be called from extensions');
-
- try {
- const extensionManager = imports.ui.main.extensionManager;
- extensionManager.openExtensionPrefs(extension.uuid, '', {});
- } catch (e) {
- if (e.name === 'ImportError')
- throw new Error('openPrefs() cannot be called from preferences');
- logError(e, 'Failed to open extension preferences');
- }
-}
<file>gdm/util.js</file>
<file>extensions/sharedInternals.js</file>
+ <file>extensions/extension.js</file>
<file>misc/animationUtils.js</file>
<file>misc/config.js</file>